{
	template:`
	<a-row>
	    <a-col :span="8">
            <a-page-header title="数据字典">
                <template #extra>
                    <a-button type="primary" @click="toEdit('');">添加</a-button>
                </template>
                <a-list :data-source="list">
                    <template #renderItem="{ item }">
                        <a-list-item>
                            <template #actions>
                                <a-typography-link v-else @click="toEdit(item.oid)">修改</a-typography-link>
                                <a-typography-text strong v-if="item.oid==model.oid">>></a-typography-text>
                                <a-typography-link v-else @click="selectDict(item)">字典值></a-typography-link>
                            </template>
                            <a-tag color="processing">{{item.type}}</a-tag>
                            {{item.name}}
                        </a-list-item>
                    </template>
                </a-list>
            </a-page-header>
	    </a-col>
	    <a-col :span="16">
	        <div id="dictData_list"></div>
	    </a-col>
	</a-row>
	`,
	props: ['localeZh','param','parentVue'],
	data:function(){
		return {
		    list:[],
			model:{},
		};
	},
	mounted(){
		this.loadList();
	},
	methods:{
	    loadList:function(oid){
			this.requestData('action/manage/dictionaryType/getList',
				{},
				data=>{
					if(!data.code){
						this.list=data.list;
						let obj=this.model;
						if(!this.model.oid) obj=this.list[0];
						if(oid){
                            for(let i=0;i<this.list.length;i++){
                                if(oid==this.list[i].oid){
                                    obj=this.list[i];
                                    break;
                                }
                            }
						}
                        if(this.list.length)
                            this.selectDict(obj);
					}
				}
			);
	    },
	    selectDict:function(dict){
	        this.model=dict;
            this.loadPage("dictData_list",
                "action/manage/dictionaryData/dictionayDataList",
                {params:{'dictionaryType.oid':dict.oid,'parentData.name':dict.name,'parentData.value':dict.type}},
                function(pv,v3){

                }.bind(this)
            );
	    },
	    toEdit:function(oid){
		    this.openPage("action/manage/dictionaryType/toEdit",{model:{oid:oid}},function(flag,obj){
		        if(flag){
		            this.loadList(obj.oid);
		        }
		    }.bind(this),"700px");
	    }
	}
}